<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>登录页</title>
    <style>
        #pwd input{
            margin-left: 23px;
        }
    </style>
</head>
<body>
    <form action="/user/login/" method="post">
        {% csrf_token %}
    {# 传统的html登录表单 #}
        <p>
            用户名:&emsp;&emsp;<input type="text" name="username" value="{{ username }}">
            <span>{{ error }}</span>
        </p>
        <p id="pwd">
            密&emsp;码:&nbsp; <input type="text" name="password" value="{{ password }}">
        </p>
        <p>
            记住用户名: <input type="checkbox" name="isSaved">
        </p>
        <p>
            <input type="submit" value="登录">
        </p>
    </form>
</body>
</html>